package com.bian.springboot03autoconfig.config;

import com.bian.springboot03autoconfig.entities.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.autoconfigure.AutoConfigureAfter;
import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * @author bianpengfei
 * @create 2019-01-26 15:18
 **/
@Configuration
@EnableConfigurationProperties(Student.class)
@AutoConfigureAfter(Student.class)
public class Teacher {
    @Autowired
    private Student student;

    @Bean
    public User user() {
        System.out.println(student.getList());
        return new User();
    }
}
